const getters = {
  sidebar: state => state.app.sidebar,
  device: state => state.app.device,
  token: state => state.user.token,
  name: state => state.user.userInfo.username, // 建立用户名的映射
  userId: state => state.user.userInfo.userId, // 映射员工id
  staffPhoto: state => state.user.userInfo.staffPhoto, // 映射员工头像
  companyId: state => state.user.userInfo.companyId, // 映射公司id
  menus: state => state.user.userInfo.roles.menus, // 映射用户权限菜单
  routes: state => state.permission.routes // 映射permission暴露的routes
}

export default getters
